package com.hshx.client;

import com.hshx.pojo.Salary;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(name = "gateway",
        path = "/salaryService",
        contextId = "SalaryClient")
public interface SalaryClient {
    @RequestMapping("/addStandardCriteria")
    boolean addStandardCriteria(Salary salary);
    @RequestMapping("/deleteStandardCriteria")
    boolean deleteStandardCriteria(Integer salary_id);
    @RequestMapping("/deleteStandardCriteriaList")
    boolean deleteStandardCriteriaList(String salary_id_list);
//    @RequestMapping("/salaryNo")
//    List<Salary> querySalaryNo(String salary_no);
    @RequestMapping("/queryStandardCriteria")
    List<Salary> queryStandardCriteria();
    @RequestMapping("/salaryID")
    Salary salaryID(@RequestParam(name="salary_id") Integer salary_id);
    @RequestMapping("/blurSalaryNo")
    boolean blurSalaryNo(@RequestParam(name="salary_no") String salary_no);
    @RequestMapping("/blurSalaryName")
    boolean blurSalaryName(@RequestParam(name="salary_name") String salary_name);
    @RequestMapping("/findPagination")
    List<Salary> findPagination(@RequestParam(name = "page") int page,@RequestParam(name = "limit") int limit);
    @RequestMapping("/findCompensationCriteriaSearch")
    List<Salary> findCompensationCriteriaSearch(@RequestParam(name = "page") int page,@RequestParam(name = "limit") int limit,@RequestParam(name = "salary_date") String salary_date,@RequestParam(name = "salary_no") String salary_no,@RequestParam(name = "salary_name") String salary_name);
    @RequestMapping("/updateStandardCriteria")
    boolean updateStandardCriteria(@SpringQueryMap Salary salary);
    @RequestMapping("/updateSalaryState")
    boolean updateSalaryState(@RequestParam(name = "salary_id") Integer salary_id,@RequestParam(name = "salary_state") Integer salary_state);
}
